package com.situ.doman;

public class test0730 {
    public static void main(String[] args) throws InterruptedException {
        Thread main = Thread.currentThread();
        System.out.println(main.getName());
        
        MyRunable runable = new MyRunable();    
        for (int i = 0; i < 10; i++) { 
            Thread temp = new Thread(runable, "a" + (i + 1));
            temp.start();
//            temp.wait();
//            temp.run();
        }
    }

}

class MyRunable implements Runnable{

    @Override
    public void run() {
        Thread t = Thread.currentThread();
        System.out.println(t.getName());
    }
    
}
